//
//  SecondCollectionViewCell.m
//  UI_19_数据请求model嵌套
//
//  Created by li cheng on 16/8/10.
//  Copyright © 2016年 li cheng. All rights reserved.
//

#import "SecondCollectionViewCell.h"

@implementation SecondCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        _myImageView = [[UIImageView alloc] init];
        [self.contentView addSubview:_myImageView];
        _myLabel = [[UILabel alloc] init];
        _myLabel.textAlignment = 1;
        [self.contentView addSubview:_myLabel];
    }
    return self;
}
- (void)layoutSubviews{
    [super layoutSubviews];
    CGFloat allHeight = 80;
    CGFloat heightImageView = 80 * 2 / 3;
    CGFloat width = self.contentView.bounds.size.width;
    _myImageView.frame = CGRectMake(0, 0, width, heightImageView);
    _myLabel.frame = CGRectMake(0, heightImageView, width, allHeight - heightImageView);
    NSLog(@"++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++%@", NSStringFromCGRect(self.contentView.bounds) );
}
@end
